﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="B_CustomerSList.aspx.cs" Inherits="RGPWEB.EN.User.B_CustomerSList" %>
<%@ Register assembly="AspNetPager" namespace="Wuqi.Webdiyer" tagprefix="webdiyer" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<link href="../../inc/Style/index.css" rel="Stylesheet" type="text/css" />
<link href="../../inc/Style/contentstyle.css" rel="Stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="../../inc/script/pub.js"></script>
<link href="../../inc/Style/GridView.css" rel="Stylesheet" type="text/css" />
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <div class="title">    
            <h1 class="on"><a href="javascript:void(0)">Customer List</a></h1>
             <h1><a href="B_Customers.aspx?type=add">New Customer</a></h1>
        </div>
        <div>
            <fieldset>
                <legend>Search Conditions</legend>
                <table style="width:100%">
                    <tr>
                        <td>REGTYPE：</td>
                        <td>
                                        <asp:RadioButtonList ID="rbl_type" runat="server" 
                                RepeatDirection="Horizontal">
                                            <asp:ListItem Value="0">Personal</asp:ListItem>
                                            <asp:ListItem Value="1">Enterprise</asp:ListItem>
                                        </asp:RadioButtonList>
                                    </td>
                        <td>Contact Name：</td>
                        <td>
                                        <asp:TextBox ID="txt_Linkmen" runat="server"></asp:TextBox>
                                        </td>
                        <td>Countries\Regions：</td>
                        <td>
                                        <asp:DropDownList ID="ddl_country" runat="server">
                                        </asp:DropDownList>
                                    </td>
                    </tr>
                    <tr>
                        <td>Industry：</td>
                        <td>
                                                <asp:DropDownList ID="ddl_indu" runat="server">
                                                    <asp:ListItem Value="0">Please Select</asp:ListItem>
                                                    <asp:ListItem Value="1">High-technology</asp:ListItem>
                                                    <asp:ListItem Value="2">Industrial manufacturing and Distribution</asp:ListItem>
                                                    <asp:ListItem Value="3">Customer Service</asp:ListItem>
                                                    <asp:ListItem Value="4">Retail /Consumer</asp:ListItem>
                                                    <asp:ListItem Value="5">Other industries</asp:ListItem>
                                                </asp:DropDownList>
                                                </td>
                        <td>Company Name：</td>
                        <td>
                                        <asp:TextBox ID="txt_company" runat="server"></asp:TextBox>
                                    </td>
                        <td colspan="2">
                            <asp:Button ID="btn_ok" runat="server" Text="Search " onclick="btn_ok_Click" />
                        </td>
                    </tr>
                </table>
            </fieldset>
        </div>
        <div>
            <fieldset>
                <legend>Customer List</legend>
                 <asp:GridView ID="grv_list" runat="server" 
                    AutoGenerateColumns="False" DataKeyNames="C_ID" 
                    onrowcommand="grv_list_RowCommand" onrowdatabound="grv_list_RowDataBound" 
                    CssClass="Grid" 
                    onselectedindexchanging="grv_list_SelectedIndexChanging">
                    <FooterStyle CssClass="GridFooter" />
                    <RowStyle CssClass="Row" />
                    <HeaderStyle CssClass="HeadingCell" />
                    <Columns>
                        <asp:TemplateField HeaderText ="REGTYPE" ItemStyle-Width="100px">
                            <ItemTemplate>
                                <asp:Label ID ="lbl_regtype" runat="server" Text='<%# Eval("C_Type") %>'></asp:Label>
                            </ItemTemplate>
                            <ItemStyle Width="100px"></ItemStyle>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText ="Industry" ItemStyle-Width="100px">
                            <ItemTemplate>
                                <asp:Label ID ="lbl_Industry" runat="server" Text='<%# Eval("C_Industry") %>'></asp:Label>
                            </ItemTemplate>
                            <ItemStyle Width="100px"></ItemStyle>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText ="Countries\Regions" ItemStyle-Width="100px">
                            <ItemTemplate>
                                <asp:Label ID ="lbl_country" runat="server" Text='<%# Eval("C_Country") %>'></asp:Label>
                            </ItemTemplate>
                            <ItemStyle Width="100px"></ItemStyle>
                        </asp:TemplateField>
                        <asp:BoundField HeaderText="Company Name" DataField="C_CompanyName" ItemStyle-Width="150px">                        
                            <ItemStyle Width="150px"></ItemStyle>
                        </asp:BoundField>
                        <asp:BoundField HeaderText="Contact Name" DataField="C_LinkMen" ItemStyle-Width="150px">                        
                            <ItemStyle Width="150px"></ItemStyle>
                        </asp:BoundField>
                        <asp:TemplateField HeaderText ="State" ItemStyle-Width="100px">
                            <ItemTemplate>
                                <asp:Label ID ="lbl_state" runat="server" Text='<%# Eval("C_State") %>'></asp:Label>
                            </ItemTemplate>
                            <ItemStyle Width="100px"></ItemStyle>
                        </asp:TemplateField>  
                        <asp:HyperLinkField DataNavigateUrlFields="C_ID" Text="Edit" DataNavigateUrlFormatString="B_Customers.aspx?Type=edit&id={0}"></asp:HyperLinkField >
                            
                        <asp:TemplateField>
                            <ItemTemplate>      
                                <asp:Button ID="btn_del" runat="server"  Text="Delete" CommandArgument='<%# Eval("C_ID")%>' CommandName="delID"/>            
                            </ItemTemplate>                
                        </asp:TemplateField>
                    </Columns>
                </asp:GridView>
                <webdiyer:AspNetPager ID="anp_list" runat="server" 
                    onpagechanging="anp_list_PageChanging"  PrevPageText="UP" 
                    FirstPageText="First" LastPageText="Last" NextPageText="Next" 
                    ScrollBars="Vertical" UrlPaging="false" ShowPageIndexBox="Always" 
                    PageIndexBoxType="DropDownList" TextBeforePageIndexBox="PageSize:" 
                    HorizontalAlign="center" CustomInfoTextAlign="Left">
                </webdiyer:AspNetPager>
            </fieldset>
        </div>
    </form>
</body>
</html>
